package com.hr.jobTimeRecord.domain;

import java.util.Date;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.hr.common.annotation.Excel;
import com.hr.common.core.domain.BaseEntity;

/**
 * 员工入职时间记录对象 job_time_record
 * 
 * @author guan
 * @date 2024-07-16
 */
public class JobTimeRecord extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 用户ID */
    @Excel(name = "用户ID")
    private Long userId;

    /** 入职时间 */
    @JsonFormat(pattern = "YYYY-MM-DD")
    @Excel(name = "入职时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date entryTime;

    /** 离职时间 */
    @JsonFormat(pattern = "YYYY-MM-DD")
    @Excel(name = "离职时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date resignationTime;

    /** 是否入职过(1代表在职，2代表已离职) */
    @Excel(name = "是否入职过(1代表在职，2代表已离职)")
    private Integer flag;

    /**
     * 时间范围筛选-开始时间
     * @param userId
     */
    private String startDate;

    /**
     * 时间范围筛选-结束时间
     * @param userId
     */
    private String endDate;

    /**
     * 时间范围筛选
     * @param
     */
    private List<Date> times;

    /**在职人数统计*/
    private Integer activeCount;
    /**在职人数统计*/
    private Integer resignedCount;

    public Integer getActiveCount() {
        return activeCount;
    }

    public void setActiveCount(Integer activeCount) {
        this.activeCount = activeCount;
    }

    public Integer getResignedCount() {
        return resignedCount;
    }

    public void setResignedCount(Integer resignedCount) {
        this.resignedCount = resignedCount;
    }

    public List<Date> getTimes() {
        return times;
    }

    public void setTimes(List<Date> times) {
        this.times = times;
    }

    public String getStartDate() {
        return startDate;
    }

    public void setStartDate(String startDate) {
        this.startDate = startDate;
    }

    public String getEndDate() {
        return endDate;
    }

    public void setEndDate(String endDate) {
        this.endDate = endDate;
    }


    public void setUserId(Long userId) 
    {
        this.userId = userId;
    }

    public Long getUserId() 
    {
        return userId;
    }
    public void setEntryTime(Date entryTime)
    {
        this.entryTime = entryTime;
    }

    public Date getEntryTime()
    {
        return entryTime;
    }
    public void setResignationTime(Date resignationTime)
    {
        this.resignationTime = resignationTime;
    }

    public Date getResignationTime()
    {
        return resignationTime;
    }
    public void setFlag(Integer flag)
    {
        this.flag = flag;
    }

    public Integer getFlag()
    {
        return flag;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("userId", getUserId())
            .append("entryTime", getEntryTime())
            .append("resignationTime", getResignationTime())
            .append("flag", getFlag())
            .toString();
    }
}
